package com.sunlands.zlcx.usercenter.repository.share;

import com.sunlands.zlcx.usercenter.domain.share.UserShareCardDO;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface UsersShareCardRepository extends JpaRepository<UserShareCardDO, Long>, JpaSpecificationExecutor<UserShareCardDO> {
    List<UserShareCardDO> findAllByLearnIdOrderByCreateTimeDesc(Long learnId);
    UserShareCardDO findByLearnIdAndCardUserId(Long learnId, Long userId);

}

